@*Hdip Project 2013-14, Student Name:- Chris Pembroke,  Student Number:- x00115839*@
@model Exercise1Project.Models.Bike

@{
    ViewBag.Title = "Edit";
    string customerId = TempData["CustomerId"].ToString();
    TempData.Keep("CustomerId");
}

<div class="viewContainerDiv2">

    <h2>Edit Bike</h2>

    @using (Html.BeginForm())
    {
        @Html.AntiForgeryToken()

        <div class="form-horizontal">

            @Html.ValidationSummary(true)
            @Html.HiddenFor(model => model.BikeID)
            @Html.HiddenFor(model => model.CustomerID)

            <div class="form-group">
                @Html.LabelFor(model => model.Make, new { @class = "control-label col-md-2" })
                <div class="col-md-10">
                    @Html.EditorFor(model => model.Make)
                    @Html.ValidationMessageFor(model => model.Make)
                </div>
            </div>

            <div class="form-group">
                @Html.LabelFor(model => model.Model, new { @class = "control-label col-md-2" })
                <div class="col-md-10">
                    @Html.EditorFor(model => model.Model)
                    @Html.ValidationMessageFor(model => model.Model)
                </div>
            </div>

            <div class="form-group">
                @Html.LabelFor(model => model.Color, new { @class = "control-label col-md-2" })
                <div class="col-md-10">
                    @Html.EditorFor(model => model.Color)
                    @Html.ValidationMessageFor(model => model.Color)
                </div>
            </div>

            <div class="form-group">
                @Html.LabelFor(model => model.Frame_Number, new { @class = "control-label col-md-2" })
                <div class="col-md-10">
                    @Html.EditorFor(model => model.Frame_Number)
                    @Html.ValidationMessageFor(model => model.Frame_Number)
                </div>
            </div>

            <div class="form-group">
                <div class="col-md-offset-2 col-md-10">
                    <input type="submit" value="Save" class="btn btn-default" />
                </div>
            </div>
        </div>
    }

    <div>
        @Html.ActionLink("Back to List", "Index", new { id = customerId })
    </div>

</div>

@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
    <link rel="stylesheet" href="@Url.Content("~/Content/customised.css")" />
}

